package 杨辉三角;

import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Test {
    public static void main(String[] args) {
        Scanner scanner=new Scanner(System.in);
        List<List<Integer>>arr=new ArrayList<>();
        int tmp=scanner.nextInt();//输入几行
        for (int i = 0; i < tmp; i++) {
            List<Integer>count=new ArrayList<>();
            for (int j = 0; j <= i; j++) {
                if(j==0||j==i){
                    count.add(1);
                }else{
                    count.add(arr.get(i-1).get(j-1)+arr.get(i-1).get(j));
                }
            }
            arr.add(count);//二维数组获取一维数组
        }
        for (List<Integer>count:arr) {
            System.out.println(count);
        }

    }
}
